import request from "@/utils/request";
/**
 * 获取专业列表
 * @param data
 * @returns {*}
 */
export function getMajorList(params) {
  return request({
    url: "/adminapi/v1.office.OfficeMajor",
    method: "get",
    params,
  });
}


/**
 * 获取专业列表
 * @param data
 * @returns {*}
 */
export function addMajorList(data) {
  return request({
    url: "/adminapi/v1.office.OfficeMajor/create",
    method: "post",
    data,
  });
}

/**
 * 获取专业列表
 * @param data
 * @returns {*}
 */
export function updateMajorList(data) {
  return request({
    url: "/adminapi/v1.office.OfficeMajor/update",
    method: "post",
    data,
  });
}

/**
 * 删除专业
 * @param data
 * @returns {*}
 */
export function deleteMajorList(data) {
  return request({
    url: "/adminapi/v1.office.OfficeMajor/delete",
    method: "post",
    data,
  });
}

/**
 * 搜索专业
 * @param data
 * @returns {*}
 */
export function searchMajorList(data) {
  return request({
    url: "/adminapi/v1.office.OfficeMajor/search",
    method: "post",
    data,
  });
}

/**
 * 查询所有学生
 * @param data
 * @returns {*}
 */
export function getStudentList(data) {
  return request({
    url: "/adminapi/v1.office.OfficeStudent",
    method: "post",
    data,
  });
}

/**
 * 搜索学生
 * @param data
 * @returns {*}
 */
export function searchStudent(data) {
  return request({
    url: "/adminapi/v1.office.OfficeStudent/search",
    method: "post",
    data,
  });
}

/**
 * 搜索学生列表
 * @param data
 * @returns {*}
 */
export function getUserList(data) {
  return request({
    url: "/adminapi/v1.office.OfficeStudent/getUserList",
    method: "post",
    data,
  });
}

/**
 * 添加所有学生
 * @param data
 * @returns {*}
 */
export function createStudent(data) {
  return request({
    url: "/adminapi/v1.office.OfficeStudent/create",
    method: "post",
    data,
  });
}

/**
 * 更新所有学生
 * @param data
 * @returns {*}
 */
export function updateStudent(data) {
  return request({
    url: "/adminapi/v1.office.OfficeStudent/update",
    method: "post",
    data,
  });
}

/**
 * 删除学生
 * @param data
 * @returns {*}
 */
export function deleteStudent(data) {
  return request({
    url: "/adminapi/v1.office.OfficeStudent/delete",
    method: "post",
    data,
  });
}

/**
 * 查询所有学生学习记录
 * @param data
 * @returns {*}
 */
export function getStudyRecordList(data) {
  return request({
    url: "/adminapi/v1.office.OfficeStudyRecord",
    method: "post",
    data,
  });
}

/**
 * 添加学生学习记录
 * @param data
 * @returns {*}
 */
export function addStudyRecord(data) {
  return request({
    url: "/adminapi/v1.office.OfficeStudyRecord/create",
    method: "post",
    data,
  });
}

/**
 * 更新学生学习记录
 * @param data
 * @returns {*}
 */
export function updateStudyRecord(data) {
  return request({
    url: "/adminapi/v1.office.OfficeStudyRecord/update",
    method: "post",
    data,
  });
}

/**
 * 删除学生学习记录
 * @param data
 * @returns {*}
 */
export function deleteStudyRecord(data) {
  return request({
    url: "/adminapi/v1.office.OfficeStudyRecord/delete",
    method: "post",
    data,
  });
}

/**
 * 查询课程列表带搜索
 * @param data
 * @returns {*}
 */
export function getClassSelectList(data) {
  return request({
    url: "/adminapi/v1.office.OfficeClass/getList",
    method: "post",
    data,
  });
}

/**
 * 查询章节列表
 * @param data
 * @returns {*}
 */
export function getChapterSelectList(data) {
  return request({
    url: "/adminapi/v1.office.OfficeChapter/getList",
    method: "post",
    data,
  });
}

/**
 * 查询课程列表
 * @param data
 * @returns {*}
 */
export function getClassList(data) {
  return request({
    url: "/adminapi/v1.office.OfficeClass/index",
    method: "post",
    data,
  });
}


/**
 * 创建课程
 * @param data
 * @returns {*}
 */
export function addClass(data) {
  return request({
    url: "/adminapi/v1.office.OfficeClass/create",
    method: "post",
    data,
  });
}

/**
 * 更新课程
 * @param data
 * @returns {*}
 */
export function updateClass(data) {
  return request({
    url: "/adminapi/v1.office.OfficeClass/update",
    method: "post",
    data,
  });
}

/**
 * 删除课程
 * @param data
 * @returns {*}
 */
export function delClass(data) {
  return request({
    url: "/adminapi/v1.office.OfficeClass/delete",
    method: "post",
    data,
  });
}

/**
 * 查询考核规则
 * @param data
 * @returns {*}
 */
export function getRulesList(data) {
  return request({
    url: "/adminapi/v1.office.OfficeRules",
    method: "post",
    data,
  });
}

/**
 * 考核规则添加或者更新
 * @param data
 * @returns {*}
 */
export function rulesCreateOrUpdate(data) {
  return request({
    url: "/adminapi/v1.office.OfficeRules/createOrUpdate",
    method: "post",
    data,
  });
}

/**
 * 删除考核规则
 * @param data
 * @returns {*}
 */
export function deleteRules(data) {
  return request({
    url: "/adminapi/v1.office.OfficeRules/delete",
    method: "post",
    data,
  });
}



/**
 * 查询课程资料
 * @param data
 * @returns {*}
 */
export function getDatumList(data) {
  return request({
    url: "/adminapi/v1.office.OfficeDatum",
    method: "post",
    data,
  });
}

/**
 * 添加或者更新课程资料
 * @param data
 * @returns {*}
 */
export function addDatumOrUpdate(data) {
  return request({
    url: "/adminapi/v1.office.OfficeDatum/createOrUpdate",
    method: "post",
    data,
  });
}

/**
 * 删除章节
 * @param data
 * @returns {*}
 */
export function delDatum(data) {
  return request({
    url: "/adminapi/v1.office.OfficeDatum/delete",
    method: "post",
    data,
  });
}

/**
 * 查询所有章节
 * @param data
 * @returns {*}
 */
export function getChapterList(data) {
  return request({
    url: "/adminapi/v1.office.OfficeChapter",
    method: "post",
    data,
  });
}

/**
 * 查询所有pid章节
 * @param data
 * @returns {*}
 */
export function getPidList(data) {
  return request({
    url: "/adminapi/v1.office.OfficeChapter/getPidList",
    method: "post",
    data,
  });
}

/**
 * 查询所有pid章节
 * @param data
 * @returns {*}
 */
export function createChapterOrUpdate(data) {
  return request({
    url: "/adminapi/v1.office.OfficeChapter/createOrUpdate",
    method: "post",
    data,
  });
}

/**
 * 删除章节
 * @param data
 * @returns {*}
 */
export function deleteChapter(data) {
  return request({
    url: "/adminapi/v1.office.OfficeChapter/delete",
    method: "post",
    data,
  });
}

/**
 * 通过id查询学生
 * @param data
 * @returns {*}
 */
export function getIdsFormUser(data) {
  return request({
    url: "/adminapi/v1.office.OfficeStudent/getIdsFormUser",
    method: "post",
    data,
  });
}


/**
 * 批量导出数据
 * @param data
 * @returns {*}
 */
export function selectAllSearchToExcel(data) {
  return request({
    url: "/adminapi/v1.office.OfficeStudent/selectAllSearchToExcel",
    method: "post",
    data,
  });
}

/**
 * 查询所有学生问题反馈
 * @param data
 * @returns {*}
 */
export function selectAllOfficeFeedback(data) {
  return request({
    url: "/adminapi/v1.office.OfficeFeedback/index",
    method: "post",
    data,
  });
}

/**
 * 删除所有学生问题反馈
 * @param data
 * @returns {*}
 */
export function delFeedback(data) {
  return request({
    url: "/adminapi/v1.office.OfficeFeedback/delete",
    method: "post",
    data,
  });
}

/**
 * 同步学生人脸识别
 * @param data
 * @returns {*}
 */
export function synchronousFace(data) {
  return request({
    url: "/adminapi/v1.office.OfficeStudent/synchronousFace",
    method: "post",
    data,
  });
}




